package com.beeweeb.services.tps.mbean;

import org.jboss.system.ServiceMBean;

public interface ThreadPoolSchedulerMBean extends ServiceMBean {
    // Scheduler parameters
    public boolean getStartQuartzAtStartup();
    public String getStartDate();
    public String getEndDate();
    public String getRepeatCount();
    public String getRepeatIntervalInMs();

    public void setStartQuartzAtStartup(boolean value);
    public void setStartDate(String value);
    public void setEndDate(String value);
    public void setRepeatCount(String value);
    public void setRepeatIntervalInMs(String value);

    // Thread pool parameters
    public int getThreadPoolSize();
    public void setThreadPoolSize(int threadPoolSize);

    // Service parameters and methods
    public String getQuartzStatus();
    public String getLastError();
    public String displayLastError();

    public String getNextFireTime();
    public void restartQuartzScheduler();
    public void stopQuartzScheduler();

    public int getEnqueuedThreadsCount();
    public int getRunningThreadsCount();

    public long getThreadAverageProcessingTime();
    public long getThreadMaximumProcessingTime();
    public long getThreadMinimumProcessingTime();
    public long getThreadStartedCount();
    public long getThreadFinishedCount();
    public String displayThreadsQueue();

    public String getJobPoolExecutorClass();
    public void setJobPoolExecutorClass(String JobExecutorClass);

    public boolean getUseCronTrigger();
    public void setUseCronTrigger(boolean useCronTrigger);

    public String getCronExpression();
    public void setCronExpression(String cronExpression);

    public String getJobPoolAcceptedCount();
    public void setJobPoolAcceptedCount(String jobPoolAcceptedCount);

    public boolean getJobPoolExclusiveExecution();
    public void setJobPoolExclusiveExecution(boolean flag);

    public String getClusterMemberName();
    public String getClusterMembers();
    public boolean isActiveClusterMember();

    public boolean getUseClustering();
    public void setUseClustering(boolean enabled);

    public boolean isClusterConnected();
     public String getJobInstanceName();

    public void setJobInstanceName(String jobInstanceName);
    public boolean isInUserTransaction();

    public void setInUserTransaction(boolean inUserTransaction);
        
    public String getClusterName();
    public void setClusterName(String clusterName);
    
    public String getClusterMulticastIpAddress();
    public void setClusterMulticastIpAddress(String clusterMulticastIpAddress);
    
    //new parameters for jobs completed notification
    public boolean isNotifyJobsCompleted();
    public void setNotifyJobsCompleted(boolean notifyJobsCompleted);

}
